import {defineStore} from 'pinia'


interface listIds{
	trackIds:[]
}

export const useStore = defineStore('main',{
	state(){
		return{
			topListIds:[] as listIds[],
			nextId:0,
		}
	},
	actions:{
		next_id(id:number){
			for(let i = 0;i<this.topListIds.length;i++){
				if(this.topListIds[i].id == id){
					this.nextId = this.topListIds[i+1].id
				}
			}
			return this.nextId
		}
	}
})